package com.cddx.logistics.mapper;

import com.cddx.logistics.domain.dto.plan.PlanCable2PageDTO;
import com.cddx.logistics.domain.dto.plan.PlanNewPageDTO;
import com.cddx.logistics.domain.dto.plan.PlanNormalPageDTO;
import com.cddx.logistics.domain.dto.plan.PlanSparePageDTO;
import com.cddx.logistics.domain.pojo.plan.PlanCable2;
import com.cddx.logistics.domain.pojo.plan.PlanNew;
import com.cddx.logistics.domain.pojo.plan.PlanNormal;
import com.cddx.logistics.domain.pojo.plan.PlanSpare;
import com.cddx.logistics.domain.vo.SelectObject;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface PlanMapper {


    List<PlanNormal> listNormalPage(PlanNormalPageDTO planNormalPageDTO);

    boolean deleteNormal(@Param("ids") List<Integer> ids);

    boolean insertNormal(PlanNormal planNormal);

    boolean updateNormal(PlanNormal planNormal);


    boolean deleteNormalById(Integer id);

    PlanNormal selectNormalById(Integer id);

    /*备品计划相关*/
    List<PlanSpare> listSparePage(PlanSparePageDTO planSparePageDTO);

    boolean insertSpare(PlanSpare planSpare);

    boolean updateSpare(PlanSpare planSpare);

    boolean deleteSpare(@Param("ids") List<Integer> ids);

    boolean deleteSpareById(Integer id);

    PlanSpare selectSpareById(Integer id);

    List<PlanNew> listNewPage(PlanNewPageDTO planNewPageDTO);

    boolean insertNew(PlanNew planNew);

    boolean updateNew(PlanNew planNew);

    boolean deleteNew(@Param("ids") List<Integer> ids);

    boolean deleteNewById(Integer id);

    PlanNew selectNewById(Integer id);

    List<PlanCable2> listCable2Page(PlanCable2PageDTO planCable2PageDTO);

    boolean insertCable2(PlanCable2 planCable2);

    boolean updateCable2(PlanCable2 planCable2);

    boolean deleteCable2(@Param("ids") List<Integer> ids);

    boolean deleteCable2ById(Integer id);

    PlanCable2 selectCable2ById(Integer id);

    boolean insertBatchNormal(List<PlanNormal> planNormals);

    List<SelectObject> queryAll();
}
